package com.daedalus.ushtrimePrintimi.komplekse;/*
 * Created with IntelliJ IDEA.
 * Author: Kostika Gorica
 * Date: 12-10-28
 * Time: 8.52.MD
 */

public class fshese {
    static final int GJERESI = 12;      // mund te jete cdo numer cift
    static final int GJATESIA = 10;

    public static void main(String[] args){
        // rreshti i pare ("+-----------------+")
        System.out.print("+");
        for (int i=1; i<GJERESI; i++){
            System.out.print("-");
        }
        System.out.println("+");

        // percaktojme numrin e hapesirave per rreshtin e pare te figures
        int nr_hapesira=GJERESI/2-1;
        int nr_slash = 0;

        // gjysma e gjysmes se siperme, pra 1/4 e figures:
        for (int i=1; i<GJATESIA/2; i++){
            System.out.print("|");
            for (int j=0;j<nr_hapesira;j++)
                System.out.print(" ");
            for (int j=0;j<nr_slash;j++)
                System.out.print("/");
            System.out.print("*");
            for (int j=0;j<nr_slash;j++)
                System.out.print("\\");
            for (int j=0;j<nr_hapesira;j++)
                System.out.print(" ");
            System.out.println("|");

            nr_hapesira--;
            nr_slash++;
        }

        // pergatitim numrin e hapsirave per pjesen e dyte te gjysmes se siperme
        nr_hapesira++;
        nr_slash--;
        // ruajme keto vlera se na duhen per gjysmen e dyte
        int nr2_hapesira=nr_hapesira;
        int nr2_slash=nr_slash;

        // pjesa e dyte e gjysmes se siperme
        for (int i=GJATESIA/2+1; i< GJATESIA; i++){
            System.out.print("|");
            for (int j=0;j<nr_hapesira;j++)
                System.out.print(" ");
            for (int j=0;j<nr_slash;j++)
                System.out.print("\\");
            System.out.print("*");
            for (int j=0;j<nr_slash;j++)
                System.out.print("/");
            for (int j=0;j<nr_hapesira;j++)
                System.out.print(" ");
            System.out.println("|");

            nr_hapesira++;
            nr_slash--;
        }

        // rreshti i mesit ("+-------------+")
        System.out.print("+");
        for (int i=1; i<GJERESI; i++){
            System.out.print("-");
        }
        System.out.println("+");

        // pjesa e pare e gjysmes se poshtme
        for (int i=1; i<GJATESIA/2; i++){
            System.out.print("|");
            for (int j=0;j<nr2_hapesira;j++)
                System.out.print(" ");
            for (int j=0;j<nr2_slash;j++)
                System.out.print("\\");
            System.out.print("*");
            for (int j=0;j<nr2_slash;j++)
                System.out.print("/");
            for (int j=0;j<nr2_hapesira;j++)
                System.out.print(" ");
            System.out.println("|");

            nr2_hapesira++;
            nr2_slash--;
        }
        nr2_hapesira--;
        nr2_slash++;
        // pjesa e dyte e gjysmes se poshtme
        for (int i=GJATESIA/2+1; i< GJATESIA; i++){
            System.out.print("|");
            for (int j=0;j<nr2_hapesira;j++)
                System.out.print(" ");
            for (int j=0;j<nr2_slash;j++)
                System.out.print("/");
            System.out.print("*");
            for (int j=0;j<nr2_slash;j++)
                System.out.print("\\");
            for (int j=0;j<nr2_hapesira;j++)
                System.out.print(" ");
            System.out.println("|");

            nr2_hapesira--;
            nr2_slash++;
        }
        // rreshti i fundit
        System.out.print("+");
        for (int i=1; i<GJERESI; i++){
            System.out.print("-");
        }
        System.out.println("+");
    }
}
